package org.huzhp;

import com.alibaba.csp.sentinel.init.InitExecutor;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * @Description: 启动类
 * @Author: huzp
 * @CreateDate: 2020/3/12 14:56
 * @Version: 1.0
 */
@SpringBootApplication(scanBasePackages = "org.huzhp")
public class ConsoleApplication {

    public static void main(String[] args) {
        triggerSentinelInit();
        SpringApplication.run(ConsoleApplication.class, args);
    }

    private static void triggerSentinelInit() {
        new Thread(() -> InitExecutor.doInit()).start();
    }

}
